20230322
[shlib.git] / testing / 2.scripttest_testing.Testing for scripttest.unit / 4.scripttest_develop.develop opt testing.dir / 3.scripttest_param_u.sh
blobfb710b51d017d61f68fbd284cec57c9e30f4352f
1 #!/bin/bash
3 . shlibinc
4 include stdio.shlib
5 include dbgout.shlib
7 init_dbglogout 2 testing 20000
9 dbgout "$0\n"
11 #err "$0\n"
13 echo $0
15 #echo xxx > /dev/pts/0
17 #ls -l> /dev/pts/0
19 #dbgout_cmd pwd
20 dbgout_cmd ls
22 cd scripts
23 ln -s `which scripttest` scripttesttest
24 #(pwd ; ls -l)> /dev/pts/0
26 dbgout "================================\n"
27 dbgout "clean test dir.\n"
28 dbgout "================================\n"
29 ./scripttesttest -c
32 # 在testing目录的测试例子中,第3个测试会遇到failed
33 # 使用-u参数将测试输出信息更新到测试log文件,再次运行测试时应该正常运行测试项。
34 dbgout "================================\n"
35 dbgout "test 5 items when error occours.\n"
36 dbgout "================================\n"
37 ./scripttesttest -n 5 -q
39 dbgout "================================\n"
40 dbgout "update output to item.\n"
41 dbgout "================================\n"
42 ./scripttesttest -n 5 -q -u
44 dbgout "================================\n"
45 dbgout "check if the item is ok.\n"
46 dbgout "================================\n"
47 ./scripttesttest -n 5 -q
49 dbgout "================================\n"
50 dbgout "clean test dir.\n"
51 dbgout "================================\n"
52 ./scripttesttest -c
54 dbgout "================================\n"